package com.zhijian.medical.dao.local;

import com.zhijian.medical.entity.po.CnasNewCorrectiveExcel;
import com.zhijian.medical.entity.vo.request.CnasNewCorrectiveExcelSearchVo;
import com.zhijian.medical.entity.vo.response.CnasNewCorrectiveExcelVo;
import java.util.List;
import org.apache.ibatis.annotations.Param;

public interface CnasNewCorrectiveExcelMapper {
    int deleteByPrimaryKey(Long id);

    int insert(CnasNewCorrectiveExcel record);

    int insertSelective(CnasNewCorrectiveExcel record);

    CnasNewCorrectiveExcel selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(CnasNewCorrectiveExcel record);

    int updateByPrimaryKey(CnasNewCorrectiveExcel record);

    /**
     * 查询总数
     *
     * @param cnasNewCorrectiveExcelSearchVo
     * @return
     */
    int count(CnasNewCorrectiveExcelSearchVo cnasNewCorrectiveExcelSearchVo);

    /**
     * 查询列表
     *
     * @param cnasNewCorrectiveExcelSearchVo
     * @return
     */
    List<CnasNewCorrectiveExcelVo> selectList(CnasNewCorrectiveExcelSearchVo cnasNewCorrectiveExcelSearchVo);

    /**
     * 查询单个
     *
     * @param cnasNewCorrectiveExcelSearchVo
     * @return
     */
    CnasNewCorrectiveExcelVo selectOne(CnasNewCorrectiveExcelSearchVo cnasNewCorrectiveExcelSearchVo);

    /**
     * 根据ID查询vo
     *
     * @param id
     * @return
     */
    CnasNewCorrectiveExcelVo selectVoById(Long id);

    /**
     * 批量删除
     *
     * @param idList
     * @return
     */
    void deleteByIdList(@Param("idList") List<Long> idList);

    /**
     * 动态删除
     *
     * @param cnasNewCorrectiveExcelSearchVo
     * @return
     */
    void deleteByCondition(CnasNewCorrectiveExcelSearchVo cnasNewCorrectiveExcelSearchVo);

    /**
     * 批量新增
     *
     * @param entities
     * @return
     */
    int insertBatch(@Param("entities") List<CnasNewCorrectiveExcel> entities);

    /**
     * 根据CnasId查询列表
     *
     * @param cnasId
     * @return
     */
    List<CnasNewCorrectiveExcelVo> selectListByCnasId(Long cnasId);

    /**
     * 根据日期查询最大编码
     * @param day
     * @return
     */
    String selectMaxCodeByDay(String day);
}